import { createApp } from 'vue'
import ElementPlus from 'element-plus'
import router from './router'
import 'element-plus/dist/index.css'
import App from './App.vue'

import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

// 使用pinia仓库
import pinia from './store'

import '@/styles/index.scss'
// 样式

const app = createApp(App)

app.use(ElementPlus, {
  locale: zhCn
})
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)}
// 这里是注册element-icon库
app.use(router)

app.use(pinia)

app.mount('#app')
